import Vue from 'vue'
import VueRouter from 'vue-router'

Vue.use(VueRouter)

const routes = [
  {
    path: '/Home',
    name: 'Home',
    component: () => import('@/views/Home.vue'),
    children: [
     
      {path:"/Home/Medicine",component:()=>import( '@/views/Medicine.vue')},
      {path:"/Home/Operation",component:()=>import('@/views/Operation.vue')},
      { path: "/Home/Role", component: () => import('@/views/Role.vue') },
      { path: "/Home/Check", component: () => import('@/views/Check.vue') },
      { path: "/Home/Dept", component: () => import('@/views/Dept.vue') },
      { path: "/Home/User", component: () => import('@/views/User.vue') },
      { path: "/Home/Upload", component: () => import('@/views/Upload.vue') },
      { path: '/Home/Permission', component: () => import('@/views/Permission.vue') },
      { path: '/Home/Register', component: () => import('@/views/Register.vue') },
      {path: '/Home/Patient', component: () => import('@/views/Patient.vue')},
      {path: '/Home/DoctorSort', component: () => import('@/views/DoctorSort.vue')},
      {path: '/Home/HospitalApply', component: () => import('@/views/HospitalApply.vue')},
      {path: '/Home/Hospitalized', component: () => import('@/views/Hospitalized.vue')},
      {path: '/Home/Sickroom', component: () => import('@/views/Sickroom.vue')},
      {path: '/Home/HospitalOperation', component: () => import('@/views/HospitalOperation.vue')}


    ]
  },
  {
    path: '/FrontPatient',
    name: 'FrontPatient',
    component: () => import('@/views/front/FrontPatient.vue'),     
  },
  { path: "/FrontPatient/PersonalCenter/:patientId", component: () => import('@/views/front/PersonalCenter.vue') }
]

const router = new VueRouter({
  routes
})

export default router
